﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MockupDesigner.Editors.TextEditors;
using System.Windows;
using System.ComponentModel;

namespace MockupDesigner.Items
{
    [SimpleTextEditor]
    public class GroupBoxItem : ResizableItem, ITextItem
    {
        // Using a DependencyProperty as the backing store for Text.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty TextProperty =
            DependencyProperty.Register("Text", typeof(string), typeof(GroupBoxItem), new UIPropertyMetadata(string.Empty));

        [Category("Prop_Content")]
        public string Text
        {
            get { return (string)GetValue(TextProperty); }
            set
            {
                if (this.Text == value) return;
                OnPropertyChanging("Text", this.Text, value);
                SetValue(TextProperty, value);
                OnPropertyChanged("Text");
            }
        }

        public bool Multiline
        {
            get { return false; }
            set
            {
                // Nothing to do
            }
        }
    }
}
